import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)


// 用来存储数据
const state = {
  asyncRouter: [],
  routerLimits: [],
  imageHost:'https://picture.bjbjkj.top/',
}
// 响应组件中的事件
const actions = {
}
// 操作数据
const mutations = {
  setRouterInfo(state, info) {
    state.asyncRouter = info
  },
  setRouterUser(state, info) {
    state.routerLimits = info
  }

}
// 用来将state数据进行加工
const getters = {

}


// 新建并暴露store
export default new Vuex.Store({
  state,
  actions,
  mutations,
  getters
})
